import request from '@/utils/request'

//获取库角色分页列表
export function getLibraryRolePageList(data) {
	return request({
		method: 'get',
		url: 'tbRoleDefinition/queryPageList',
		params: data
	})
}

//获取库角色列表
export function getLibraryRoleList(data) {
	return request({
		method: 'get',
		url: 'tbRoleDefinition/queryList',
		params: data
	})
}

//添加库角色
export function addedLibraryRole(data) {
	return request({
		method: 'post',
		url: 'tbRoleDefinition/add',
		data
	})
}

//修改库角色
export function updateLibraryRole(data) {
	return request({
		method: 'post',
		url: 'tbRoleDefinition/update',
		data
	})
}

//删除库角色
export function deleteLibraryRole(id) {
	return request({
		method: 'get',
		url: 'tbRoleDefinition/delete/' + id
	})
}

//获取库角色详情
export function queryLibraryRole(id) {
	return request({
		method: 'get',
		url: 'tbRoleDefinition/query/' + id
	})
}

//修改库角色状态
export function updateRoleStatus(data) {
	return request({
		method: 'post',
		url: 'tbRoleDefinition/updateDel',
		data
	})
}